import React from 'react';
import { render } from 'react-dom';
import { Provider } from 'react-redux';
import { Router, Route, browserHistory } from 'react-router'
// import { syncHistoryWithStore } from 'react-router-redux'
import configureStore from './stores';
import routes from './routes'
// import App from '../containers/App';
import Login from './containers/Login'
import NewsList from './containers/NewsList';
import NewsViewer from './containers/NewsViewer'

const store = configureStore();
// const history = syncHistoryWithStore(browserHistory, store)

render(
  <Provider store={store}>
    <Router history={browserHistory}>
      <Route path="newslist" component={NewsList} />
      <Route path="newsviewer/:id" component={NewsViewer} />
      <Route path="login" component={Login} />
    </Router>
  </Provider>,
  document.getElementById('app')
);
